package com.itheima.stock.service;

import com.itheima.stock.pojo.domain.PermissionsTreeDomain;
import com.itheima.stock.pojo.entity.SysPermission;

import java.util.List;

public interface PermissionService {

    /**
     * 根据用户id查询用户所有权限
     * @param id
     * @return
     */
    public List<SysPermission> getPermissionByUserId(Long id);

    /**
     * 获取树状权限菜单数据
     * @param sysPermissions
     * @param pid
     * @param isOnlyMenuType
     * @return
     */
    public List<PermissionsTreeDomain> getPermissionTree(List<SysPermission> sysPermissions,Long pid,Boolean isOnlyMenuType);

}
